package org.zuel.boot.demo.component;

import org.apache.shiro.authc.UsernamePasswordToken;
import org.zuel.boot.demo.constant.LoginType;

/**
 * @Description:
 * @Author: Athrun
 * @Date: 2019/4/5
 * @Version 1.0
 */
public class LoginToken extends UsernamePasswordToken {

    //登录方式
    private LoginType loginType;

    //微信code
    private String openid;

    public LoginToken(LoginType loginType, final String username, final String password) {
        super(username, password);
        this.loginType = loginType;
    }

    public LoginToken(LoginType loginType, String openid) {
        super(openid, openid);
        this.loginType = loginType;
        this.openid = openid;
    }

    public LoginType getLoginType() {
        return loginType;
    }

    public void setLoginType(LoginType loginType) {
        this.loginType = loginType;
    }

    public String getOpenid() {
        return openid;
    }

    public void setOpenid(String openid) {
        this.openid = openid;
    }
}
